﻿using System;
using System.Collections.Generic;
using NTTDATA.BEENChina.ResultCertification.Config; 

namespace NTTDATA.BEENChina.ResultCertification.Checker.Numeric
{
   
    [Serializable]
    [VerfityAttribute(Id = "VerfityD0007", Name = "文字记载栏是一个问号时抽出检证", CategoryType = EnumCategoryType.数值, Model = true)]
    public class VerfityD0007 : VerfityOneResult
    {
 
        public override bool CheckResult(List<List<string>> result, string entryCommon)
        {
            bool bresult = false;
            if (result == null)
            {
                return false;
            }


            bresult = CheckSpecificCharacter(result, GetSpeicficResult, CheckspecificResult); 

            if (bresult)
            {
                System.Console.WriteLine("VerfityD0007");
            }

            return bresult;
        }

        private   string GetSpeicficResult(string colResult)
        {
            var splitResult = new Split.SplitEntryResult(ChildImageObject.CategorySetting.DataFormat, colResult);
            return splitResult.GetText();
        }

        private   bool CheckspecificResult(string result)
        {
            return result.Equals("?");
        }
    }
}
